<?php
namespace Core\Widget;

abstract class  WidgetAbstract{

    public abstract function form();
    public abstract function form_update($blockInstance_Item, $blockClass_Item);
    public abstract function form_content($blockInstance_Item);
    public abstract function render($blockInstanceItem);
    public abstract function save($allParams);
    public abstract function saveContent($allParams);
    public abstract function preview($allParams);
    public abstract function getProgramCode();
    public function quick_info($blockInstanceItem){
        return $blockInstanceItem->name;
    }

    protected function buildJSONString($arrData){
        return json_encode($arrData);
    }

    protected function getArrayFromJson($jsonStr){
        return json_decode($jsonStr, true);
    }

}